home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.cs.arizona.edu
/
ftp.cs.arizona.edu.tar
/
ftp.cs.arizona.edu
/
icon
/
newsgrp
/
group94b.txt
/
000115_icon-group-sender _Sun Nov 20 16:57:46 1994.msg
< prev
next >
Wrap
Internet Message Format
|
1995-02-09
|
2KB
Received: by cheltenham.cs.arizona.edu; Sun, 20 Nov 1994 18:15:15 MST
To: icon-group-l@cs.arizona.edu
Date: 20 Nov 1994 16:57:46 -0700
From: dave@cs.arizona.edu (Dave Schaumann)
Message-Id: <3aonpq$4kp@caslon.CS.Arizona.EDU>
Organization: University of Arizona CS Department, Tucson AZ
Sender: icon-group-request@cs.arizona.edu
References: <3aofof$f5m@highway.leidenuniv.nl>
Subject: Re: optional typing in Icon (longish)
Errors-To: icon-group-errors@cs.arizona.edu
In article <3aofof$f5m@highway.leidenuniv.nl>,
Jan-Peter de Ruiter <ruiter@ruls41.LeidenUniv.nl> wrote:
[much deletia]
>o How much optimisation opportunities will arise from having
> variables with a fixed type.
For types that have primitive operations that can be implemented
in a few machine operations (few enough to be in-lined reasonably),
this can be a significant savings. Not only do you get the benefit
of not having to go through the general case (which probably involves
a function call), but you also get the benefit of less stuff dynamically
allocated, so the garbage collecter has less work to do.
For stuff like lists and tables, where most operations are going to
be function calls anyway (and probably require garbage collection
anyway), there probably won't be any benefit at all.
>o How much speed & size performance gain could be expected from
> this.
I wouldn't look for a lot of size gain from this sort of optimization.
Much of the size of a compiled Icon program is due to the support
libraries, which you'll need anyway. Speed is really where the win
is in this kind of optimization. How much speed you can get is a
matter for research.
>o Could a version of the Icon runtime environment be developed
> that gives information on how often the type of all variables
> changes during program execution (in order to obtain reliable
> statistics on how often variables are, in effect, of fixed type)
Sure. In fact, you could probably do this with MT Icon (multi-tasking
Icon) reasonably easy.
(see ftp:cs.arizona.edu/icon/monitors for info on MT Icon)
-Dave